package com.nursinghome.admin.service;

import com.nursinghome.bean.Elderly;
import com.nursinghome.exception.NurisingHomeException;

import java.util.List;

public interface ElderlyService {
    //查询所有的老人
    List<Elderly> selectAll(String pageNum, String eusername);
    //新增老人
    Boolean addElderly(Elderly elderly) throws NurisingHomeException;
    //删除老人
    Boolean delByEid(Long eid) throws NurisingHomeException;
    //修改老人
    Boolean update(Elderly elderly) throws NurisingHomeException;
    //根据eid查询老人
    Elderly selectByEid(Long eid);
    //根据eusername查询老人
    Elderly selectByEusername(String eusername);
    //给老人分配护工
    Boolean assignCaregivers(Long eid, Integer[] mids);

    //根据老人id查询护工的id
    Integer[] selectByEidAndEM(Long eid);
}
